package com.ys.enume.bi;

/**
 * bi分类模块业务流水分析汇总表
 */
public class BiClassifyModuleEnum {

    public enum ClassifyType {
        PROCURE("采购服务", 0),
        STORAGE("仓储服务", 1),
        LOGISTICS("物流服务", 2),
        PUBLIC_SERVE("公共服务", 3),
        OPERATE("运营服务", 4),
        HR("人力行政", 5),
        ;

        public String name;
        public Integer value;

        private ClassifyType(String name, Integer value) {
            this.name = name;
            this.value = value;
        }

        public static String getName(Integer value) {
            for (ClassifyType e : ClassifyType.values()) {
                if (e.value.equals(value)) {
                    return e.name;
                }
            }
            return "";
        }

        public static Integer getValue(String name) {
            for (ClassifyType e : ClassifyType.values()) {
                if (e.name.equals(name) ) {
                    return e.value;
                }
            }
            return null;
        }


    }



    public enum DataType {
        INCOME("收入", 0),
        OUTCOME("支出", 1),
        PROFIT("利润", 2),
        ;

        public String name;
        public Integer value;

        private DataType(String name, Integer value) {
            this.name = name;
            this.value = value;
        }

        public static String getName(Integer value) {
            for (DataType e : DataType.values()) {
                if (e.value.equals(value)) {
                    return e.name;
                }
            }
            return "";
        }
    }

}
